import { Callout } from '@theguild/components'

export const REPEAT = 'designator that follows the value for the number of'

# Duration

A string representing a duration conforming to the `ISO8601` standard, such as `P1W1DT13H23M34S`.

- **P** is the duration designator (for the _period_) placed at the start of the duration
  representation.
  - **Y** is the year {REPEAT} years.
  - **M** is the month {REPEAT} months.
  - **W** is the week {REPEAT} weeks.
  - **D** is the day {REPEAT} days.
- **T** is the time designator that precedes the time components of the representation.
  - **H** is the hour {REPEAT} hours.
  - **M** is the minute {REPEAT} minutes.
  - **S** is the second {REPEAT} seconds.

<Callout>
  Note the time designator, **T**, that precedes the time value. Matches moment.js, Luxon and
  DateFns implementations.

`,`/`.` is valid for decimal places and `+`/`-` is a valid prefix.

</Callout>
